/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package Util;

/**
 *
 * @author antonio
 */

import com.hp.hpl.jena.query.*;
import com.hp.hpl.jena.rdf.model.*;

public class CubeFactory {
    
    private QuerySolution soln; 
    private String label;
    
    public CubeFactory(QuerySolution soln, String label)
    {
        this.soln = soln;
        this.label = label;
    }
    
    public Cube createCube()
    {
        Cube cubix = new Cube();
        
         
            
            Literal  abs = soln.getLiteral("abstract");
            
            //Literal km = soln.getLiteral("km");
            
            System.out.print("CreateCube: " + this.label + "\t" + abs.getString() + "\t" + "\n\n");
        
        cubix.setLabel(this.label);
        cubix.setAbs(abs.getString()); 
        
        return cubix;
    }

}
